package com.ziyun.pop.modules.storeMaterials.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.ziyun.pop.modules.storeMaterials.dao.StoreMaterialOutDetailDao;
import com.ziyun.pop.modules.storeMaterials.entity.StoreMaterialOutDetailEntity;
import com.ziyun.pop.modules.storeMaterials.entity.StorematerialinOutEntity;
import com.ziyun.pop.modules.storeMaterials.service.StoreMaterialOutDetailService;
import org.springframework.stereotype.Service;

import java.math.BigDecimal;
import java.util.List;

/**
 * @Author ZhaoWei
 * @Date 2018/10/11 13:42
 * @Version V1.0
 */
@Service("storeMaterialOutDetailService")
public class StoreMaterialOutDetailServiceImpl extends ServiceImpl<StoreMaterialOutDetailDao,StoreMaterialOutDetailEntity> implements StoreMaterialOutDetailService{

	@Override
	public void saveBatch(List<StoreMaterialOutDetailEntity> detialListSave, StorematerialinOutEntity storematerialinOutEntity) {
		baseMapper.saveBatch(detialListSave,storematerialinOutEntity);
	}

	@Override
	public List<StoreMaterialOutDetailEntity> getListstoreMaterialOutDetail(Integer outId, String outNO) {
		return baseMapper.getListstoreMaterialOutDetail(outId,outNO);
	}

	@Override
	public BigDecimal getMaterialQuantityByMaterialId(String materialId, String outNo) {
		return baseMapper.getMaterialQuantityByMaterialId(materialId,outNo);
	}
}
